#include <stdio.h>
#include <unistd.h>

int main()
{
    int count = 10;
    while (count >= 0)
    {
        printf("%-2d", count);
        fflush(stdout);
        printf("\r");
        sleep(1);
        count--;
    }
    printf("\n");
    return 0;
}
